{% extends "main.html" %}

{% block content %}
<div class="content-box">
  <div class="content-box-header">
    <h3>Suppliers</h3>
    <ul class="content-box-tabs">
      <li><a href="#tab1" class="default-tab">List</a></li>
        <li><a href="/fornecedores/novo">Add Supplier</a></li>
    </ul>
    <div class="clear"></div>
</div>

<div class="content-box-content">
  <div class="tab-content default-tab" id="tab1">
     
      <table>
        <thead>
          <tr>
            <th>Name</th>
            <th>Description</th>
            <th>TIN</th>
            <th>Address</th>
            <th>Telephone</th>
            <th>Email</th>
            <th></th>
          </tr>
        </thead>
	{% for fornecedor in object_list %}
	<tr> 
	  <td>{{fornecedor.nomeFornecedor}}</td>
	  <td>{{fornecedor.descricao}}</td>
	  <td>{{fornecedor.nif}}</td>
	  <td>{{fornecedor.morada}}</td>
	  <td>{{fornecedor.telefone}}</td>
          <td>{{fornecedor.email}}</td>
	    <td><a href="{% url editar_fornecedor fornecedor.id %}">Edit</a> | <a href="{% url apagar_fornecedor fornecedor.id %}">Delete</a></td>
        </tr> 
	{% endfor %}
      </table>

 
    </div>
  </div>
</div>
{% endblock %}
